
<!DOCTYPE HTML PUBLIC "-//W3C//DTD -//W3C//DTD HTML 4.01//EN//EN" "">
<%@page import="comparator.SortByPriority"%>
<%@ page contentType="text/html; charset=utf-8" %>
<%@page import="controller.Controller"%>
<%@page import="java.util.*,dataBase.*"%>
<%@page import="com.google.appengine.api.datastore.Key"%>
<%@page import="comparator.SortByStatus"%>
<%@page import="comparator.SortByDate"%>
<%@page import="sessionMenegment.SessionMgr"%>
<%@page import="language.LangFactory"%>
<%@page import="language.LangIntrf"%>
<%@page import="util.Util"%>

<%
	SessionMgr sessionMgr = SessionMgr.getInst();
	boolean user = sessionMgr.checkUser(request,session);
	if(!user)
		response.sendRedirect("home.jsp");
%>
<%
	LangFactory langFactory= new LangFactory();
	String langName = request.getParameter("lang");

	LangIntrf lang =null;
	if(langName!=null){
		lang = langFactory.getLang(request.getParameter("lang"));
		session.setAttribute("lang",langName);
	}
	else
		lang = langFactory.getLang((String)session.getAttribute("lang"));
	String langSign = lang.getLang();
	
	
%>
<html>
	<head>
		<link rel="icon" href="../images/synca.png" type="image/x-icon"/> 
		<link rel="shortcut icon" href="../images/synca.png" type="image/x-icon"/>
		<link href="../style2.css" rel="stylesheet" type="text/css" />
		<link href="../e.css" rel="stylesheet" type="text/css" />
        <% 
        	Controller controller = Controller.getInstance();
        	Business business2 =  controller.getBiz((String)session.getAttribute("userNameBusiness"));
        	if(business2==null){
        		response.sendRedirect("home.jsp");
        	}
        	String border = business2.getBorderColor();
        	String background = business2.getBackground();
        	String messageBG = business2.getSecBackground();
         	
        	if (border!=null && background!=null && messageBG!=null ){
        %>
        
        <style type="text/css">
        	body {
        		background-color: <%=background%>;
        	}
        	
        	#container {
        		background-color: <%=background%>;
        	}
        	#header {
        		background-color: <%=messageBG%>;
        		border-bottom: solid 2px <%=border%>;
        	}
        	#headerLogedIn{
        		background-color: <%=messageBG%>;
        		border-bottom: solid 2px <%=border%>;
        	}
        	#headerLogedIn #logo{
        		color: <%=background%>;
        	}
        	.menu_nav li,.menu_nav_logedIn li {
        		background-color: <%=background%>;
        		border:solid 2px <%=border%>;
        	}
        	#left_sidebar {
        		background-color: <%=background%>;
        	}
        	#left_sidebar button{
        		color:<%=background%>;
        		background-color: <%=messageBG%>;
        		border:solid 2px <%=border%>;
        	}
        	
        	.control_bar {
        		background-color: <%=background%>;
        	}
        	#main_content{
        		background-color: <%=background%>;
        	}
        	#footer {

        		background-color: <%=messageBG%>;
        		border-top: solid 2px <%=border%>;
        	}
        	#stylized .formButton{
        		color:<%=background%>;
        		background-color: <%=messageBG%>;
        		border:solid 2px <%=border%>;
        	}
        	#stylized{
        		background:<%=background%>;
        		border:solid 2px <%=border%>;
        	}
        	.messageBox{
        		background-color: <%=messageBG%>;
        		border: solid 2px <%=border%>;
        		
        	}
        	.messageBox button{
        		background-color: <%=background%>;
        		border:solid 2px <%=border%>;
        	}
        	.menu_nav {
        		background-color:<%=messageBG%>;
        	}
        	.menu_nav_logedIn {
        		background-color:<%=messageBG%>;
        	}
        	.side_buttons li {
        		background-color: <%=messageBG%>;
        		border:solid 2px <%=border%>;
        	}
        	.list{
        		border: solid 2px <%=messageBG%>;
        	}
        	#left_sidebar form{
        		border:solid 2px <%=border%>;
        	}
        	.list{
        		border: solid 2px <%=border%>;
        	}
        	
        	
        	/*-----  e.css  -----*/
        	
        	
        	.statusChange,.sendMessage{
        		background-color: <%=background%>;
        		border:solid 2px <%=border%>;
        	}
        	.heading {
        		background-color:<%=messageBG%>;
        	}
        	.heading2 {
        		background-color:<%=messageBG%>;
        	}
        	.wraper {
        		background-color:<%=messageBG%>;
        		border-color: <%=border%>;
        	}
        	.wraper2 {
        		background-color:<%=messageBG%>;
        	}
        	.content {
        		background-color:<%=messageBG%>;
        	}
        	.currentStatus {
        		border:solid 2px <%=border%>;
        		background-color: #ccffff;
        		
        	}
        	
        </style>
        <%} %>
        <script type="text/javascript" src="../jquery-1.3.2.min.js"></script>
        <script type="text/javascript" src="../jquery.tools.min.js"></script>
		<script type="text/javascript" src="../jquery-ui-1.7.1.custom.min.js"></script>
        <script type="text/javascript" src="../jquery.address-1.4.min.js"></script>
        <script type="text/javascript" src="../javascript/interface.js"></script>
        <script type="text/javascript" src="../javascript/jquery.js"></script>
        <script type="text/javascript" src="../javascript/jquery.validate.js"></script>
        
		<title>Synca</title>
        <script>
			jQuery(document).ready(
				function() {
					$.address.history(false).strict(false).change(function(event){
						var tab = event.value;					
						(tab=='boxes' || tab=='') ? visiableMain('boxes') : hiddenMain('boxes');
						(tab=='orderList') ? visiableMain('orderList') : hiddenMain('orderList');
						(tab=='statistics') ? visiableMain('statistics') : hiddenMain('statistics');

						
   					}).history(true);
					$("#messageBox").hide();
					$("#messageBox2").hide();
					$("#messageBox3").hide();
					
					$("#logOut").click(function(){
							$.post("logOutBusiness",function(){$(location).attr('href','home.jsp');});
					});
					$("#profile").click(function(){
						//$.post("myProfileBusiness",function(){$(location).attr('href','myProfileBusiness2.jsp');});
						window.location.href = "myProfileBusiness2.jsp";
				    });
					$(".closeBox").click(function(){
						$(this).parent().slideUp(500);
					});
					$("#newOrder").click(function(){
							$("#messageBox").slideToggle(500);
					});
					$("#newOrderButton").click(function(){
							$("#messageBox").slideToggle(500);
					});
					// Example 1.2: Sortable and connectable lists
					$('#example-1-2 .sortable-list').sortable({
						connectWith: '#example-1-2 .sortable-list'
					});

					  $(".content").hide();
					  /* $(".arrow").click(function()
					  {
						  var elem = $(this).parent();
						  if(listOrBoxes=='boxes')
						  		changeDivContent("statusDiv",$(this).parent());
						  else
							  	openMessageBox('changeStatus',elem);
					  }); */
					  $(".arrow").live('click',function()
					  {
						  var elem = $(this).parent();
						  if(listOrBoxes=='boxes')
						  		changeDivContent("statusDiv",$(this).parent());
						  else
							  	openMessageBox('changeStatus',elem);
					  });
					  $(".print").click(function(){
						  if(listOrBoxes=='boxes')
						  	  window.open('print.jsp?orderNum='+$(this).parent().parent().parent().find("#orderId").val());
						  else
						  	  window.open('print.jsp?orderNum='+$(this).parent().parent().parent().parent().parent().parent().parent().find("#orderId").html());
					  });
					  $(".message").click(function()
					  {
						  var elem = $(this).parent();
						  if(listOrBoxes=='boxes')
						  	  changeDivContent("messageDiv",elem);
						  else
							  openMessageBox('changeMessage',elem);
					  });
					  $(".cogWheel").click(function()
					  {
						  if(listOrBoxes=='boxes')
						  	  changeDivContent("settingDiv",$(this).parent());
						  else
							  openMessageBox('settingsBox',$(this).parent().parent());
					  });
					  $(".trash").click(function(){
						  var a = confirm("Are you sure you want to delete this order");
						  if(listOrBoxes=='boxes')
							  elem = $(this).parent().find("#orderId").val();
						  else
							  elem = $(this).parent().parent().find("#orderNum").html();
						  if(a==true){
							  /*alert($(this).parent().find("#orderId").val());*/
						  	  $.post("deleteOrderBusiness",{orderID: elem},function(){$(location).attr('href','allOrders.jsp');});
						  }
						  else
							  alert("not delete");
					  });
					  $(".exit").click(function(){
						  	$(this).parent().hide(500);
					  });
					  $("#newOrderBusiness").validate({ 
						   rules: { 
						   		orderID: {
						   			required: true,
						   	      	digits: true
						   		},
								phone:{
									required: true,
								}
						   },
						   messages: { 
							   orderID: "Please enter an order ID or get the auto ID",
							   phone: "Please enter a valid phone number"
						   },
						   errorPlacement: function(error, element) { 
						   		element.parent().find("#s1").html(error);

						   },
						   success: function(label){
							   label.html("");
						   }
					});
					
					  $(".statusChange").live('click',function (){
						  openLoading();
						  if(listOrBoxes=='boxes')
						  	  elem = $(this).parent().parent().parent().find("#orderId").val();
						  else
							  elem = $(this).parent().parent().parent().find("#orderId").html();
						  
						  $.post("changeStatusBusiness", {orderID: elem,newStatus:$(this).val()}, function() {
							  //$(location).attr('href','allOrders.jsp#'+listOrBoxes);
							  location.reload();
							  changeStatus($(this).html('il'),$(this).parent().parent());
							  },"html");
							  
							  
					 });
					  $(".sendMessage").tooltip({position: "center right",
							
							// a little tweaking of the position
							offset: [-2, 10],
						
							// use the built-in fadeIn/fadeOut effect
							effect: "fade",
						
							// custom opacity setting
							opacity: 0.7});
					  $(".sendMessage").click(function (){
						  openLoading();
						  elem = $(this).parent().parent().parent().find("#orderId").val();
							  $.post("sendMessageBusiness", {orderID: elem,message:$(this).val()}, function() {
								  location.reload();
								  changeStatus($(this).html('il'),$(this).parent().parent());
								  },"html"); 
										  
										  
						});
					  $(".closeOrder").live('click',function (){
					  	  elem = $(this).parent().parent().parent();//.find("#orderId").val();
						  if(listOrBoxes=='boxes'){
							  $.post("activeOrderBusiness", {orderID: elem.find("#orderId").val(),isActive:"false"}, function() {
								  closeOrder(elem,elem.find("#orderId").val());
								  },"html"); 
					  	  }	
						  else{
							  $.post("activeOrderBusiness", {orderID: elem.find("#orderId").html(),isActive:"false"}, function() {
								  closeOrder(elem,elem.find("#orderId").html());
								  
								  },"html");
							  
						  }
										  
						});
					  $(".side_buttons li").click(function(){
						  var val = $(this).val();
						  if(val==1)
							  window.location.href = "allOrders.jsp";
						  else if(val==2)
							  window.location.href = "statistics.jsp";
						  else if(val==3)
							  window.location.href = "history.jsp";
						  else if(val==4)
							  window.location.href = "closedOrders.jsp";
					  });
					  changeStatus = function(val,elem){
						  
					  }
					  changeDivContent = function(divName,elem){
						//  confirm(divName);
							if(divName=='settingDiv'){
								openDiv('settingDiv',elem)
						//		confirm("if");
					  		}
							else{
								
								closeDiv('settingDiv',elem);
							//	confirm("else");
							}
						//	confirm("xfx");
					  		(divName=='messageDiv') ? openDiv('messageDiv',elem) : closeDiv('messageDiv',elem);
					  		
							(divName=='statusDiv') ? openDiv('statusDiv',elem) : closeDiv('statusDiv',elem);
					  }
					  
					  openDiv = function(divName1,elem){
						  
						  elem.find('#'+divName1).attr('class','content');
						//  confirm("1");
						  //if(elem.find('#'+divName1).is(':not(:visiable)')){  
						//	  confirm("3");
							  elem.find('#'+divName1).slideToggle(500);	  
					//	  }
						//  confirm("2");
						  return true;
					  }
					  
					  closeDiv = function(divName,elem){
						  elem.find('#'+divName).attr('class','hiddenMain');
					//	  if(elem.find('#'+divName).is(':visiable')){
							  elem.find('#'+divName).hide(500);	  
					//	  }
						  return true;
					  }
					
				}
			);
			var closeOrder = function(elem,val){
				var tr = $(".tableView tr");
				  tr.each(function(){
					  if($(this).find("#orderNum").html()==val)
						  $(this).hide(500);
					  if(listOrBoxes!='boxes')
						  elem.hide();	
				  });
				  
				  $(".sortable-item").each(function(){
					  if($(this).find("#orderId").val()==val)
						  $(this).remove();
				  });
			}
			var openMessageBox = function(divName,elem){				
				$("#messageBox2 #orderId").html(elem.parent().find("#orderNum").html());
				$("#messageBox2 #curStatus").html(elem.parent().find("#currentStatusId").html());
				if(divName=="changeStatus"){					 
					$("#messageBox2 #changeStatus li").remove();
					$("#messageBox2 #changeStatus ul").replaceWith(elem.parent().find("#statusList").html());	
				}	
				else if(divName=="settingsBox"){
					$("#messageBox2 #settingsBox #details ").html(elem.find("#detailsTable").html());
					$("#messageBox2 #settingsBox #comments ").html(elem.find("#commentsTable").html());
					$("#messageBox2 #settingsBox #phone ").val(elem.find("#phoneTable").html());
					$("#messageBox2 #settingsBox #email ").val(elem.find("#emailTable").html());
					$("#messageBox2 #settingsBox #destAddress ").val(elem.find("#destTable").html());
					$("#messageBox2 #settingsBox #orderNum ").val(elem.find("#orderNum").html());
					if(elem.find("#sendMailTable").html()=="yes")
						$("#messageBox2 #settingsBox input[name=sendMail]").attr("checked",true);
					else
						$("#messageBox2 #settingsBox input[name=sendMail]").attr("checked",false);
				}
				if($("#messageBox2").is(':visible')==false)
					$("#messageBox2").slideToggle(500);
				$("#messageBox2 div").hide();				
				$("#messageBox2 #"+divName).show();				
				/* alert(elem.parent().find("#currentStatusId").html()); */
			}
			var openLoading = function(){
				$("#messageBox3").show();
			}
			var visiableMain = function(tab){
				$('#main_content #'+tab).attr('class','');
				$("#main_content #"+tab).css('visibility','visible');
				listOrBoxes = tab;
				//window.scrollTo(0, 0);
			}
			
			var hiddenMain = function(tab){
				$("#main_content #"+tab).attr('class','hiddenMain');
				$("#main_content #"+tab).css('visibility','hidden');
				//window.scrollTo(0, 0);
			}
				
			var listOrBoxes = 'boxes';

			<%
			String businessUserName =(String)session.getAttribute("userNameBusiness");
			//String businessUserName ="liel";
			if (businessUserName==null){
				response.sendRedirect("home.jsp");
			}
			Business business = business2;// ConnectToDataBase.getInst().getBiz(businessUserName);
			System.out.println("business: "+ business);
			
			/* if (business==null)
				response.sendRedirect("home.jsp"); */
				
			List<Status> listOfStatuses = controller.getStatusesOfBiz(businessUserName);
			System.out.println("listOfStatuses: "+ listOfStatuses);
			if (listOfStatuses==null)
				response.sendRedirect("home.jsp");
			
			//List<Order> list = controller.getOrdersOfBiz(businessUserName);
			List<Order> list = controller.getAvailableOrdersOfBiz(businessUserName);
			System.out.println("list: "+ list);
			
			if (list==null)
				response.sendRedirect("home.jsp");
			
			long delay = Util.getFirstDelay(list,business.getOrderUrgencyTime());
			if(delay!=0){
			%>
				var interval = setInterval(function(){location.reload();},<%=delay%>);
			<%}%>
		</script>
        
	</head>

	<body>
	<%
	ArrayList<String> listOfMessages = business.getMessages();
	
	/*
	List<Order> list = new ArrayList<Order>();
	//for (int i=0; i<10; i++){
	Order o1 = new Order();
	Date d = new Date(2009, 5, 31);
	//o1.setStartTime(format.parse(d.toString()));
	o1.setStartTime(d);
	//System.out.println(d); 
	o1.setDestAdd("aaa");
	o1.setOrderNum("1");
	
	List<Level> lis = new ArrayList<Level>();
	Level l = new Level();
	Status s = listOfStatuses.get(0);
	l.setCurrentStatus(s);
	lis.add(l);
	
	o1.setLevelsList(lis);
	
	//			s.setStatusName("")
	//			l.setCurrentStatus()
	//			l.add(new Level)
	//			o1.s

	list.add(o1);

	Order o2 = new Order();
	o2.setStartTime(new Date(2008, 3, 31));
	o2.setDestAdd("bbb");
	o2.setOrderNum("2");

	lis = new ArrayList<Level>();
	l = new Level();
	s = listOfStatuses.get(1);
	l.setCurrentStatus(s);
	lis.add(l);
	
	o2.setLevelsList(lis);
	
	list.add(o2);

	Order o3 = new Order();
	o3.setStartTime(new Date(2009, 1, 31));
	o3.setDestAdd("ccc");
	o3.setOrderNum("3");

	lis = new ArrayList<Level>();
	l = new Level();
	s = listOfStatuses.get(2);
	l.setCurrentStatus(s);
	lis.add(l);
	
	o3.setLevelsList(lis);
	
	list.add(o3);

	Order o4 = new Order();
	o4.setStartTime(new Date(2011, 5, 31));
	o4.setDestAdd("ddd");
	o4.setOrderNum("4");

	lis = new ArrayList<Level>();
	l = new Level();
	s = listOfStatuses.get(0);
	l.setCurrentStatus(s);
	lis.add(l);
	
	o4.setLevelsList(lis);
	
	
	list.add(o4);
*/
	String sortBy = request.getParameter("sort");
	//sortBy = "date";
	
	
	Comparator<Order> comparByDate = SortByDate.getInstance().getDateComparator();
	//get the status comparator
	SortByStatus statusSort = new SortByStatus();
	statusSort.setBusiness(business);
	Comparator<Order> comparByStatus = statusSort.getStatusComparator();
	
	Comparator<Order> finalComparator=null;
	if (sortBy==null)
		finalComparator = null;
	else if (sortBy.equals("date"))
		finalComparator = comparByDate;
	else if (sortBy.equals("status"))
		finalComparator = comparByStatus;
	else if (sortBy.equals("priority")){
		SortByPriority sort = new SortByPriority();
		sort.setUrgencyTime(business.getOrderUrgencyTime());
		finalComparator = sort.getCom();
	}
	//default
		

	//if the field is valid
	if (finalComparator != null) {
		Collections.sort(list, finalComparator);
	}
	
	ArrayList<Order> list1 = new ArrayList<Order>();
	ArrayList<Order> list2 = new ArrayList<Order>();
	ArrayList<Order> list3 = new ArrayList<Order>();

	int listSize = list.size();
	int numOfRound = listSize / 3;
	int mod = listSize % 3;
	int location = 0;
	for (int j = 0; j < numOfRound; j++) {
		list1.add(list.get(location));
		location++;
		list2.add(list.get(location));
		location++;
		list3.add(list.get(location));
		location++;
	}
	if (mod == 1) {
		list1.add(list.get(location));
	} else if (mod == 2) {
		list1.add(list.get(location));
		location++;
		list2.add(list.get(location));
	}

	%>
	<%if(session.getAttribute("validErrorNewOrder")!=null){%>
		<div id="errorBox" class="messageBox" style="text-align: center;font-size:130%;">
    		<img src="../closed12.png" class="closeBox"/>
    		<table>
	    		<tr align="<%=lang.getAlign()%>">
	    			<td><img src="../images/error.png" class="error"></td>
	    			<td><%=session.getAttribute("validErrorNewOrder")%></td>
	    		</tr>
    		</table>
    		
    		<br/>
    		
    	</div>
    	<%session.setAttribute("validErrorNewOrder",null);%>
	<%}%>
    <div id="messageBox"  class="messageBox" style="text-align: <%=lang.getAlign()%>">
    	<img src="../closed12.png" class="closeBox"/>
    	<form action="newOrderBusiness" method="POST" id="newOrderBusiness" accept-charset="ISO-8859-1">
            <table dir="<%=lang.getDirection()%>">
            	<tr>
            		<td align="<%=lang.getAlign()%>"><%=lang.getORDER_ID_LABEL() %></td>
            		<td align="<%=lang.getAlign()%>"><input type="text" name="orderID" id="orderID" value="<%=controller.getNextFreeOrderId(businessUserName)%>">*</td>
            	</tr>
            	<tr>
            		<td align="<%=lang.getAlign()%>"><%=lang.getCURRENT_STATUS_LABEL() %></td>
            		<td align="<%=lang.getAlign()%>">
            			<select name="currentStatus"> 
			            <% 
			            int statuseLength1 = listOfStatuses.size();
			            for (int i=0;i<statuseLength1;i++){
			            	Status currentStatus = listOfStatuses.get(i);
			            %> 
			            	<option value="<%=i%>" > <%=currentStatus.getStatusName()%></option>  
			            <%}%>
			             </select>
			        </td>
			    </tr>
			    <tr>
            		<td align="<%=lang.getAlign()%>"><%=lang.getPRIORITY_LABEL() %></td>
            		<td align="<%=lang.getAlign()%>">
            			<select name="priority"> 
			            	<option value="0"> <%=lang.getLOW_PRIORITY_LABEL() %></option>
			            	<option value="1" selected="selected"> <%=lang.getMEDIUM_PRIORITY_LABEL() %></option>
			            	<option value="2"> <%=lang.getHIGH_PRIORITY_LABEL() %></option>  
		            	</select>
			        </td>
			    </tr>
			    <tr>
			    	<td align="<%=lang.getAlign()%>"><%=lang.getDEST_ADDRESS_LABEL() %></td>
			    	<td align="<%=lang.getAlign()%>"><input type="text" name="destAddress"></td>
			    </tr>
			    <tr>
			    	<td align="<%=lang.getAlign()%>"><%=lang.getPHONE_NUMBER_LABEL() %></td>
			    	<td align="<%=lang.getAlign()%>"><input type="text" name="phone" id="phone">*</td>
			    </tr>
			    <tr>
			    	<td align="<%=lang.getAlign()%>"><%=lang.getEMAIL_LABEL() %></td>
			    	<td align="<%=lang.getAlign()%>"><input type="text" name="email" id="email"></td>
			    </tr>
			    <tr>
			    	<td align="<%=lang.getAlign()%>"><%=lang.getDETAILS_LABEL() %></td>
			    	<td align="<%=lang.getAlign()%>"><textarea name="details"></textarea></td>
			    </tr>
			    <tr>
			    	<td align="<%=lang.getAlign()%>"><%=lang.getCOMMENTS_LABEL_BIZ() %></td>
			    	<td align="<%=lang.getAlign()%>"><textarea name="comments"></textarea></td>
			    </tr>
			    <tr>
			    	<td align="<%=lang.getNotAlign()%>"><input type="checkbox" name="sendMail"></td>
			    	<td align="<%=lang.getAlign()%>"><%=lang.getSEND_MAIL_LABEL() %></td>
			    </tr>
			    <tr><td></td><td align="left"><label id="s1" style="color: #ff0000;"></label></td></tr>
            	<tr><td></td><td align="left"><button type="submit" value="Submit"><%=lang.getSUBMIT_BUTTON() %></button></td></tr>
            </table>
        </form> 
    </div>
    <div id="messageBox2" class="messageBox" style="text-align: <%=lang.getAlign()%>">
    	<img src="../closed12.png" class="closeBox"/><br/>
    	<%if(lang.getAlign().equals("left")){ %>
    	<%=lang.getORDER_NUBER_LABEL() %> <label id="orderId"></label><br/>
    	<%=lang.getCURRENT_STATUS_LABEL() %> <label id="curStatus"></label><br/>
    	<%}else{ %>
    	<label id="orderId"></label><%=lang.getORDER_NUBER_LABEL() %><br/>
    	<label id="curStatus"></label><%=lang.getCURRENT_STATUS_LABEL() %> <br/>
    	<%} %> 
    	<div id="changeStatus">
    		<ul>
    		<%int index1=0;
    		for (Status status:listOfStatuses){%>
    			<li value="<%=index1%>" id="statusChange" class="statusChange" title="<%=status.getStatusName()%>"><%=status.getStatusName()%></li>
    		<%index1++;
    		} %>
    		</ul>
    	</div>
    	<div id="changeMessage">
    		<ul>
    			<%            
                   	index1=0;
                   	for (String message : listOfMessages){                   		
                   	%>
                   	<li value="<%=index1 %>" id="sendMessage" class="sendMessage" title="<%=message %>"><%=message %></li>
                   	<%
                   		//end of else
                   		index1++;
                   	}//end of for
                %>
    		</ul>
    		<label style="font-size: 14px;"><%=lang.getSEND_FREE_TEXT_LABEL() %></label>   <br>    
                  	          
           	<center> 
           	<form action="sendFreeMessageBusiness" method="post" accept-charset="ISO-8859-1">	
           		<textarea rows="3" cols="20" name="message"></textarea><br>
           		<input type="hidden" value="123" name="orderID"/>
           		<button  type="submit" ><%=lang.getSEND_BUTTON() %></button> 
           	</form>
           	</center> 
    	</div>
    	<div id="settingsBox">
    	
           	<form action="orderSettingBusiness" method="post" accept-charset="ISO-8859-1">
           	<table>
           		<tr>
           			<td><textarea rows="4" cols="20" name="details" id="details"></textarea></td>        
           			<td valign="top"><%=lang.getDETAILS_LABEL() %></td>
           		</tr>
           		<tr>
           			<td><textarea rows="4" cols="20" name="comments" id="comments"></textarea></td>
           			<td valign="top"><%=lang.getCOMMENTS_LABEL_BIZ() %></td>
           		</tr>
           		<tr>
           			<td><input type="text" name="destAddress" value="" id="destAddress" /></td>
           			<td valign="top"><%=lang.getDEST_ADDRESS_LABEL() %></td>
           		</tr>
           		<tr>
           			<td><input type="text" name="email" value="" id="email"/></td>
           			<td valign="top"><%=lang.getEMAIL_LABEL() %></td>
           		</tr>
           		<tr>
           			<td><%=lang.getSEND_MAIL_LABEL() %></td>
           			<td align="left"><input type="checkbox" name="sendMail"></td>
           		</tr>
           		<tr>
           			<td align="left"><button type="submit" value="Save" >Save</button></td>
           			<td></td>
           		</tr>
           		<tr></tr>
           		<tr>
           			<td valign="top"><label class="print"><%= lang.getPRINT_LABEL() %></label></td>
           			<td align="left"><img src="../images/printer4.png" class="print"></td>
           		</tr>
           	</table>
           		<input type="hidden" value="" name="orderNum" id="orderNum"/>
     				
           	</form>
         	 
         	
    	</div>
    	
    </div>
    <div id="messageBox3" class="messageBox" style="text-align: <%=lang.getAlign()%>">
    	<img src="../images/loading.gif" width="20px"><%=lang.getLOADING_LABEL() %>
    </div>
<div id="container">
		
		<div id="headerLogedIn">

        <div class="menu_nav_logedIn">
            <ul id="menu">
                <li id="profile"><%=lang.getMY_PROFILE_LABEL() %></li>
                <li id="logOut"><%=lang.getLOG_OUT_BUTTON() %></li>
            </ul>
        </div>	
        	
		</div>

		<div id="left_sidebar">
		<%if (business.getLogoPic()!=null){ %>
			<img src="../showImage?imageKey=<%=business.getUserName() %>" width="150" />
		<% }else{ %>
			<img src="../images/tempLogo.png" width="150" />
		<%} %>
		
            <div class="side_buttons">
                <ul>
                    <li id="newOrderButton" value="0"><%=lang.getNEW_ORDER_BUTTON() %></li>
                    <li value="1" ><%=lang.getALL_ORDERS_BUTTON() %></li>
                   	<li value="2"><%=lang.getSTATISTIC_BUTTON() %></li>
                   	<li value="3"><%=lang.getHISTORY_BUTTON() %></li>
                   	<li value="4"><%=lang.getCLOSED_BUTTON() %></li>
                </ul>
        	</div>
		</div>
			<div class="control_bar">
			<%if(lang.getAlign().equals("left")){ %>
            <%=lang.getSORT_BY_LABEL()%><select name="select" onChange="location=this.options[this.selectedIndex].value">  
                        <option value=" "> </option>
                        <option value="allOrders.jsp?sort=status"><%=lang.getSORT_BY_STATUS_LABEL() %></option>  
                        <option value="allOrders.jsp?sort=date"><%=lang.getSORT_BY_DATE_LABEL() %></option>   
                        <option value="allOrders.jsp?sort=priority"><%=lang.getSORT_BY_PRIORITY_LABEL() %></option>     
                     </select >  
            <%}else{ %>
                     <select name="select" onChange="location=this.options[this.selectedIndex].value">  
                        <option value=" "> </option>
                        <option value="allOrders.jsp?sort=status"><%=lang.getSORT_BY_STATUS_LABEL() %></option>  
                        <option value="allOrders.jsp?sort=date"><%=lang.getSORT_BY_DATE_LABEL() %></option>
                        <option value="allOrders.jsp?sort=priority"><%=lang.getSORT_BY_PRIORITY_LABEL() %></option>     
                     </select > 
                     <%=lang.getSORT_BY_LABEL()%> 
            
            <%} %>
            <a href="#orderList"><div  class="list">
            	<img src="../list2.png"/>
            </div></a>
            <a href="#boxes"><div class="list">
            	<img src="../squares2.png"/>
            </div></a>
            <div class="list" id="newOrder">
            	<img src="../add2.png"/>
            </div>
            <!--<img src="list.png" class="list"/>
            <img src="Squares.png" class="squares"/>
            <img src="add.png" class="add"/>-->
        </div>	
<div id="main_content">
<div id="boxes">
	<div id="example-1-2">
	<div class="column left first">
	<ul class="sortable-list">
	<%
		for (Order i : list1) {
	%>
	
		<li class="sortable-item" id="sortable-item">
			<div class = "wraper<%=i.isDelay(business.getOrderUrgencyTime(),null)?"2":""%>">
				<img src="../exit3.png"  class="exit"/>
					<p class="heading"><%=lang.getORDER_LABEL() %> <%=i.getOrderNum()%></p>				
					<label class="heading2" > <%=lang.getSTATUS_LABEL() %> <%=(controller.getCurrentStatusOfOrder(i)) %></label>
				<input type="hidden" value="<%=i.getOrderNum()%>" id = "orderId"/>
				<img src="../arrowright3.png"  class="arrow"/><br>
                     <img src="../message4.png" class="message" />
                     <img src="../cogWheel4.png" class="cogWheel" />
                     <img src="../trash4.png" class="trash" >
                     	
                     <div id="settingDiv" class="content">
                     	<form action="orderSettingBusiness" method="post" accept-charset="ISO-8859-1">
                     		<%=lang.getPRIORITY_LABEL() %><br/>
                     		<select name="priority"> 
				            	<option value="0" <%=i.getUrgency()==0? "selected=\"selected\"" : ""%>> <%=lang.getLOW_PRIORITY_LABEL() %></option>
				            	<option value="1" <%=i.getUrgency()==1? "selected=\"selected\"" : ""%>> <%=lang.getMEDIUM_PRIORITY_LABEL() %></option>
				            	<option value="2" <%=i.getUrgency()==2? "selected=\"selected\"" : ""%>> <%=lang.getHIGH_PRIORITY_LABEL() %></option>  
			            	</select><br/>
                     		<%=lang.getDETAILS_LABEL() %><br/>
                     		<textarea rows="4" cols="20" name="details"><%=i.getDetails() %></textarea><br/>
                     		<%=lang.getCOMMENTS_LABEL_BIZ() %><br/>
                     		<textarea rows="4" cols="20" name="comments"><%=i.getComments().getValue() %></textarea><br/>
                     		<%=lang.getDEST_ADDRESS_LABEL() %><br/>
                     		<input type="text" name="destAddress" value="<%=i.getDestAdd()%>"/><br/>
                     		<%=lang.getEMAIL_LABEL() %><br/>
                     		<input type="text" name="email" value="<%=i.getEmail()%>"/><br/>
                     		<input type="checkbox" <%= i.getSendMail()? "checked='checked'":""%> name="sendMail"><%=lang.getSEND_MAIL_LABEL() %><br/>
                     		<input type="hidden" value="<%=i.getOrderNum() %>" name="orderNum"/>
               				<input type="submit" value="<%=lang.getSAVE_BUTTON() %>" />
                     	</form><br/>
                   		<img src="../images/printer4.png" class="print"> <label class="print"><%= lang.getPRINT_LABEL() %></label>
                     </div>
                     
                     <div id="statusDiv" class="content">
                     	<ul>
                     	<%
                     	int index=0;
                     	List<String> tmpList = i.getStatusNamesList();
                     	for (String status:tmpList){
                     		if (status.equals(controller.getCurrentStatusOfOrder(i))){
                     			//if(true){
                     			
                     		%>
                     			<li value="<%=index%>" id="statusChange" class="statusChange currentStatus" title="<%=status%>">
                         		<%=status%>
                         		</li>
                     		<%
                     		}
                     		else{
                     		%>
                     		<li value="<%=index%>" id="statusChange" class="statusChange" title="<%=status%>">
                     		<%=status%>
                     		</li>
                     	<%
                     		}//end of else
                     	index++;
                     	}//end of for
                     	%>
                     	<li class="closeOrder" title="Close The Order"><%=lang.getCLOSE_ORDER_BUTTON() %></li>
                     	
                     	</ul>
                     </div>
                     <div id="messageDiv" class="content">
						<ul>
                     	<%
                     	
                     	index=0;
                     	for (String message : listOfMessages){
                     		
                     		
                     	%>
                     	<li value="<%=index %>" id="sendMessage" class="sendMessage" title="<%=message %>"><%=message %></li>
                     	<%
                     		//end of else
                     		index++;
                     	}//end of for
                     	%>
                     	</ul>  
                     	<label style="font-size: 14px;"><%=lang.getSEND_FREE_TEXT_LABEL() %></label>   <br>    
                     	          
                     	<center> 
                     	<form action="sendFreeMessageBusiness" method="post" accept-charset="ISO-8859-1">	
                     		<textarea rows="3" cols="20" name="message"></textarea><br>
                     		<input type="hidden" value="<%=i.getOrderNum() %>" name="orderID"/>
                     		<input type="submit" value="Send" /> 
                     	</form>
                     	</center> 
                     	</div>
		</div>
	</li>
	<%
		}
	%>
	</ul>
	</div>
	
	<div class="column left">
	<ul class="sortable-list">
	<%
		for (Order i : list2) {
	%>
	
		<li class="sortable-item" id="sortable-item">
			<div class = "wraper<%=i.isDelay(business.getOrderUrgencyTime(),null)?"2":""%>">
				<img src="../exit3.png"  class="exit"/>
					<p class="heading"><%=lang.getORDER_LABEL() %> <%=i.getOrderNum()%></p>				
					<label class="heading2" > <%=lang.getSTATUS_LABEL() %> <%=(controller.getCurrentStatusOfOrder(i)) %></label>
				<input type="hidden" value="<%=i.getOrderNum()%>" id = "orderId"/>
				<img src="../arrowright3.png"  class="arrow"/><br/>
                     <img src="../message4.png" class="message" />
                     <img src="../cogWheel4.png" class="cogWheel" />
                     <img src="../trash4.png" class="trash" >
                     	
                     <div id="settingDiv" class="content">
                     	<form action="orderSettingBusiness" method="post" accept-charset="ISO-8859-1">
                     		<%=lang.getPRIORITY_LABEL() %><br/>
                     		<select name="priority"> 
				            	<option value="0" <%=i.getUrgency()==0? "selected=\"selected\"" : ""%>> <%=lang.getLOW_PRIORITY_LABEL() %></option>
				            	<option value="1" <%=i.getUrgency()==1? "selected=\"selected\"" : ""%>> <%=lang.getMEDIUM_PRIORITY_LABEL() %></option>
				            	<option value="2" <%=i.getUrgency()==2? "selected=\"selected\"" : ""%>> <%=lang.getHIGH_PRIORITY_LABEL() %></option>  
			            	</select><br/>
                     		<%=lang.getDETAILS_LABEL() %><br/>
                     		<textarea rows="4" cols="20" name="details"><%=i.getDetails() %></textarea><br/>
                     		<%=lang.getCOMMENTS_LABEL_BIZ() %><br/>
                     		<textarea rows="4" cols="20" name="comments"><%=i.getComments().getValue() %></textarea><br/>
                     		<%=lang.getDEST_ADDRESS_LABEL()%><br/>
                     		<input type="text" name="destAddress" value="<%=i.getDestAdd()%>"/><br/>                   	
                     		<%=lang.getEMAIL_LABEL() %><br/>
                     		<input type="text" name="email" value="<%=i.getEmail()%>"/><br/>
                     		<input type="checkbox" <%= i.getSendMail()? "checked='checked'":""%> name="sendMail"><%=lang.getSEND_MAIL_LABEL() %><br/>
                     		<input type="hidden" value="<%=i.getOrderNum() %>" name="orderNum"/>
               				<input type="submit" value="<%=lang.getSAVE_BUTTON() %>" />
                     	</form><br/>
                   		<img src="../images/printer4.png" class="print" > <%=lang.getPRINT_LABEL() %>
                     </div>
                     
                     <div id="statusDiv" class="content">
                     	<ul>
                     	<%
                     	int index=0;
               
                     	List<String> tmpList = i.getStatusNamesList();
                     	for (String status:tmpList){
                     		if (status.equals((controller.getCurrentStatusOfOrder(i)))){
                     			//if(true){
                     			
                     		%>
                     			<li value="<%=index%>" id="statusChange" class="statusChange currentStatus" title="<%=status%>">
                         		<%=status%>
                         		</li>
                     		<%
                     		}
                     		else{
                     		%>
                     		<li value="<%=index %>" id="statusChange" class="statusChange" title="<%=status%>">
                     		<%=status%>
                     		</li>
                     	<%
                     		}//end of else
                     	index++;
                     	}//end of for
                     	%>
                     	<li class="closeOrder" title="Close The Order"><%=lang.getCLOSE_ORDER_BUTTON() %></li>                
                     	</ul>
                     </div>
                     <div id="messageDiv" class="content">
				<ul>
                     	<%
                     	
                     	index=0;
                     	for (String message : listOfMessages){
                     		
                     		
                     	%>
                     	<li value="<%=index %>" id="sendMessage" class="sendMessage" title="<%=message %>"><%=message %></li>
                     	<%
                     		//end of else
                     		index++;
                     	}//end of for
                     	%>
                     	</ul>   
                     	<label style="font-size: 14px;"><%=lang.getSEND_FREE_TEXT_LABEL() %></label>   <br>    
                     	          
                     	<center> 
                     	<form action="sendFreeMessageBusiness" method="post" accept-charset="ISO-8859-1">	
                     		<textarea rows="3" cols="20" name="message"></textarea><br>
                     		<input type="hidden" value="<%=i.getOrderNum() %>" name="orderID"/>
                     		<input type="submit" value="<%=lang.getSAVE_BUTTON() %>" /> 
                     	</form>
                     	</center> 
                     	</div>
		</div>
	</li>
	<%
		}
	%>
	</ul>
	</div>
	
	<div class="column left">
	<ul class="sortable-list">
	<%
		for (Order i : list3) {
	%>
	
		<li class="sortable-item" id="sortable-item">
			<div class = "wraper<%=i.isDelay(business.getOrderUrgencyTime(),null)?"2":""%>">
				<img src="../exit3.png"  class="exit"/>
					<p class="heading"><%=lang.getORDER_LABEL() %> <%=i.getOrderNum()%></p>				
					<label class="heading2" > <%=lang.getSTATUS_LABEL() %> <%=(controller.getCurrentStatusOfOrder(i)) %></label>
				<input type="hidden" value="<%=i.getOrderNum()%>" id = "orderId"/>
				<img src="../arrowright3.png"  class="arrow"/><br/>
                     <img src="../message4.png" class="message" />
                     <img src="../cogWheel4.png" class="cogWheel" />
                     
                     <img src="../trash4.png" class="trash" >	
                     
                     <div id="settingDiv" class="content">
                     	<form action="orderSettingBusiness" method="post" accept-charset="ISO-8859-1">
                     		<%=lang.getPRIORITY_LABEL() %><br/>
                     		<select name="priority"> 
				            	<option value="0" <%=i.getUrgency()==0? "selected=\"selected\"" : ""%>> <%=lang.getLOW_PRIORITY_LABEL() %></option>
				            	<option value="1" <%=i.getUrgency()==1? "selected=\"selected\"" : ""%>> <%=lang.getMEDIUM_PRIORITY_LABEL() %></option>
				            	<option value="2" <%=i.getUrgency()==2? "selected=\"selected\"" : ""%>> <%=lang.getHIGH_PRIORITY_LABEL() %></option>  
			            	</select><br/>
                     		<%=lang.getDETAILS_LABEL() %><br/>
                     		<textarea rows="4" cols="20" name="details"><%=i.getDetails() %></textarea><br/>
                     		<%=lang.getCOMMENTS_LABEL_BIZ() %><br/>
                     		<textarea rows="4" cols="20" name="comments"><%=i.getComments().getValue() %></textarea><br/>
                     		<%=lang.getDEST_ADDRESS_LABEL()%><br/>
                     		<input type="text" name="destAddress" value="<%=i.getDestAdd()%>"/><br/>                     		
                     		<%=lang.getEMAIL_LABEL() %><br/>
                     		<input type="text" name="email" value="<%=i.getEmail()%>"/><br/>
                     		<input type="checkbox" <%= i.getSendMail()? "checked='checked'":""%> name="sendMail"><%=lang.getSEND_MAIL_LABEL()%><br/>
                     		<input type="hidden" value="<%=i.getOrderNum() %>" name="orderNum"/>
               				<input type="submit" value="<%=lang.getSAVE_BUTTON() %>" />
                     	</form><br/>
                   		<img src="../images/printer4.png" class="print" > <%=lang.getPRINT_LABEL() %>
                     </div>
                     
                     <div id="statusDiv" class="content">
                     	<ul>
                     	<%
                     	int index=0;
                     	List<String> tmpList = i.getStatusNamesList();
                     	for (String status:tmpList){
                     		if (status.equals((controller.getCurrentStatusOfOrder(i)))){
                     			//if(true){
                     			
                     		%>
                     			<li value="<%=index%>" id="statusChange" class="statusChange currentStatus" title="<%=status%>">
                         		<%=status%>
                         		</li>
                     		<%
                     		}
                     		else{
                     		%>
                     		<li value="<%=index%>" id="statusChange" class="statusChange" title="<%=status%>">
                     		<%=status%>
                     		</li>
                     	<%
                     		}//end of else
                     	index++;
                     	}//end of for
                     	%>
                     	<li class="closeOrder" title="Close The Order"><%=lang.getCLOSE_ORDER_BUTTON() %></li>
                     	</ul>
                     </div>
                     <div id="messageDiv" class="content">
				<ul>
                     	<%
                     	
                     	index=0;
                     	for (String message : listOfMessages){
                     		
                     		
                     	%>
                     	<li value="<%=index %>" id="sendMessage" class="sendMessage" title="<%=message %>"><%=message %></li>
                     	<%
                     		//end of else
                     		index++;
                     	}//end of for
                     	%>
                     	</ul>
                     	<label style="font-size: 14px;"><%=lang.getSEND_FREE_TEXT_LABEL() %></label>   <br>    
                     	          
                     	<center> 
                     	<form action="sendFreeMessageBusiness" method="post" accept-charset="ISO-8859-1">	
                     		<textarea rows="3" cols="20" name="message"></textarea><br>
                     		<input type="hidden" value="<%=i.getOrderNum() %>" name="orderID"/>
                     		<input type="submit" value="<%=lang.getSEND_BUTTON() %>" /> 
                     	</form>
                     	</center> 
                     	</div>
		</div>
	</li>
	<%
		}
	%>
	</ul>
	</div>
	
</div>
        
</div> <!-- end of Boxes -->
<center>
<div id="orderList" style="height: 100%;">
<%if(lang.getAlign().equals("left")){ %>
<table border="1" style="border: 2px solid" class="tableView">
	<tr>
		<td><%=lang.getORDER_NUMBER_TABLE_LABEL() %></td>
		<td><%=lang.getCURRENT_STATUS_TABLE_LABEL() %></td>
		<td><%=lang.getPHONE_TABLE_LABEL()%></td>
		<td><%=lang.getEMAIL_TABLE_LABEL()%></td>
		<td><%=lang.getMESSAGES_TABLE_LABEL() %></td>
		<td><%=lang.getSETTING_TABLE_LABEL() %></td>
		<td><%=lang.getDELETE_TABLE_LABEL() %></td>
	</tr>
	<%
	for(Order order : list){
	%>
	<tr align="center">
		<td id="orderNum"><%=order.getOrderNum() %></td>
		<td><%=controller.getCurrentStatusOfOrder(order) %><img src="../arrowright3.png" class="arrow"/></td>
		<td id="phoneTable"><%=order.getPhoneNumber().getNumber() %></td>
		<td id="emailTable"><%=order.getEmail() %></td>
		<td><img src="../message4.png" class="message"/></td>
		<td><img src="../cogWheel4.png" class="cogWheel"/></td>
		<td><img src="../trash4.png" class="trash"/></td>
		<td class="hiddenLabel" id="currentStatusId" ><%=controller.getCurrentStatusOfOrder(order) %></td>	
		<td class="hiddenLabel" id="statusList" >
			<ul>
			<%List<String> statusList = order.getStatusNamesList();
			  int i=0;
			  for(String status : statusList){%>
				<li value="<%=i%>" id="statusChange" class="statusChange" title="<%=status%>"><%=status%></li>
			  <%i++;
			  } %>
			  <li class="closeOrder" title="Close The Order"><%=lang.getCLOSE_ORDER_BUTTON() %></li>
			</ul>
		</td>	
		<td class="hiddenLabel" id="commentsTable" ><%=order.getComments().getValue() %></td>
		<td class="hiddenLabel" id="detailsTable" ><%=order.getDetails() %></td>
		<td class="hiddenLabel" id="destTable" ><%=order.getDestAdd()%></td>
		<td class="hiddenLabel" id="sendMailTable" ><%=order.getSendMail() ? "yes" : "no"%></td>
		
	</tr>
	
	<%} %>
</table>	
<%}else{ %>
<table border="1" style="border: 2px solid" class="tableView">
	<tr>
		<td><%=lang.getDELETE_TABLE_LABEL() %></td>
		<td><%=lang.getSETTING_TABLE_LABEL() %></td>
		<td><%=lang.getMESSAGES_TABLE_LABEL() %></td>
		<td><%=lang.getEMAIL_TABLE_LABEL()%></td>
		<td><%=lang.getPHONE_TABLE_LABEL()%></td>
		<td><%=lang.getCURRENT_STATUS_TABLE_LABEL() %></td>
		<td><%=lang.getORDER_NUMBER_TABLE_LABEL() %></td>		
	</tr>
	<%
	for(Order order : list){
	%>
	<tr align="center">
		<td class="hiddenLabel" id="commentsTable" ><%=order.getComments().getValue() %></td>
		<td class="hiddenLabel" id="detailsTable" ><%=order.getDetails() %></td>
		<td class="hiddenLabel" id="destTable" ><%=order.getDestAdd()%></td>
		<td class="hiddenLabel" id="sendMailTable" ><%=order.getSendMail() ? "yes" : "no"%></td>
	
		<td class="hiddenLabel" id="statusList" >
			<ul>
			<%List<String> statusList = order.getStatusNamesList();
			  int i=0;
			  for(String status : statusList){%>
				<li value="<%=i%>" id="statusChange" class="statusChange" title="<%=status%>"><%=status%></li>
			  <%i++;
			  } %>
			<li class="closeOrder" title="Close The Order"><%=lang.getCLOSE_ORDER_BUTTON() %></li>
			</ul>
		</td>	
		<td class="hiddenLabel" id="currentStatusId" ><%=controller.getCurrentStatusOfOrder(order) %></td>	
		<td><img src="../trash4.png" class="trash"/></td>
		<td><img src="../cogWheel4.png" class="cogWheel"/></td>
		<td><img src="../message4.png" class="message"/></td>
		<td id="emailTable"><%=order.getEmail() %></td>
		<td id="phoneTable"><%=order.getPhoneNumber().getNumber() %></td>
		<td><%=controller.getCurrentStatusOfOrder(order) %><img src="../arrowright3.png" class="arrow"/></td>
		<td id="orderNum"><%=order.getOrderNum() %></td>
		
	</tr>
	
	<%} %>
</table>
<%} %>
</div>
<div id="statistics">
	<%if (Controller.getInstance().getBiz((String) session.getAttribute("userNameBusiness")).getAllOrdersList().size()==0) { %>
		there are no orders
	<%} else {%>
		<div id="chart_div" class="chart_div"></div>
	<%} %>
</div>
</center>
		<div class="clearer">&nbsp;</div>
	</div>	


		<div id="footer">
	<a href="allOrders.jsp?lang=he"><img src="../images/hebrew.gif" width="30px" style="float: left; margin-top: 0.5%; margin-left: 0.5%;"/></a>
	<a href="allOrders.jsp?lang=en"><img src="../images/english.gif" width="30px" style="float: left; margin-top: 0.5%;margin-left: 0.5%;"/></a>

		<center>
			<p><%=lang.getCOPY_RIGHT_LABEL() %>  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;   &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;               
				<a href="home.jsp"><%=lang.getHOME_BUTTON() %></a> &nbsp;&nbsp;| &nbsp;&nbsp;
				<a href="home.jsp#customers"><%=lang.getCONTACT_BUTTON()%></a> &nbsp;&nbsp;|&nbsp;&nbsp;
				<a href="home.jsp?#about"><%=lang.getABOUT_BUTTON() %></a>
			</p>
		</center>
	</div>
</div>


	</body>

</html>
